
local module = _G["BlinkHealthTextModule"]

if select(2, UnitClass("player")) ~= "HUNTER" or not module then return end

local L_FOCUSED_FIRE = "Focused Fire"
if GetLocale()=="koKR" then
L_FOCUSED_FIRE = "집중 사격"
end

module.config = {
	[L_FOCUSED_FIRE] = {
		spellid = 82692
	},
}

function module:init()
	self:update()
end

function module:update()
	self.primary = GetSpecialization()
	for auraName, t in pairs(self.config) do
		if t.talent and t.talent > 0 then
			local name, iconTexture, tier, column, selected, available = GetTalentInfo(t.talent);
			if name and available then
				self.config[auraName].use = true
				if t.event and self.addon and self.addon.mainFrame then
					self.addon.mainFrame:RegisterEvent(t.event)
				end
			end
		else
			self.config[auraName].use = false
			if IsPlayerSpell(t.spellid) then
				self.config[auraName].use = true
				if t.event and self.addon and self.addon.mainFrame then
					self.addon.mainFrame:RegisterEvent(t.event)
				end
			end
		end
	end
end

function module:getPlayerText()
	return self:getAuraCount("pet", "광기", "HELPFUL")
end